<!-- This file is intended for testing only-->
{% extends "index.html" %}

{% block inline_navi %}
<a href="/">Home</a>&nbsp;>&nbsp;Passwort ändern
{% endblock %}

{% block content %}
<h1>Passwort ändern</h1>

<div id="detail_table">
    <form action="{% url usermanagement.views.changepasswordview %}" method="post">
    {% csrf_token %}
    {{ form.non_field_errors }}
        <table>
            <tr>
                <th class="detail_table_head">altes Passwort</th>
            </tr>
            <!-- old Password -->
            <tr>
                {% if form.old_password.errors %}
                <th class="form_error"><label for="id_password">Passwort erforderlich:</label></th>
                {% else %}
                <th><label for="id_password">Passwort:</label></th>
                {% endif %}
                <td>{{ form.old_password }}</td>
            </tr>
            <tr>
                <th class="detail_table_head">neues Passwort</th>
            </tr>
            <!-- new Password -->
            <tr>
                {% if form.password.errors %}
                <th class="form_error"><label for="id_password">Passwort erforderlich:</label></th>
                {% else %}
                <th><label for="id_password">Passwort:</label></th>
                {% endif %}
                <td>{{ form.password }}</td>
            </tr>
            <!-- Password repetition -->
            <tr>
                {% if form.password_repetition.errors %}
                <th class="form_error"><label for="id_password_repetition">Passwort richtig wiederholen</label></th>
                {% else %}
                <th><label for="id_password_repetition">Wiederholung:</label></th>
                {% endif %}
                <td>{{ form.password_repetition }}</td>
            </tr>
            <tr>
                <td colspan="2" align="center" style="padding-top: 10px;">
                    <input type="submit" value="Ändern" />
                </td>
            </tr>
        </table>
    </form>
</div>

{% endblock %}

